<?xml version="1.0" encoding="utf-8"?>
<!--
                                                                                     
 h       t     t                ::       /     /                     t             / 
 h       t     t                ::      //    //                     t            // 
 h     ttttt ttttt ppppp sssss         //    //  y   y       sssss ttttt         //  
 hhhh    t     t   p   p s            //    //   y   y       s       t          //   
 h  hh   t     t   ppppp sssss       //    //    yyyyy       sssss   t         //    
 h   h   t     t   p         s  ::   /     /         y  ..       s   t    ..   /     
 h   h   t     t   p     sssss  ::   /     /     yyyyy  ..   sssss   t    ..   /     
                                                                                     
	<https://y.st./>
	Copyright © 2017 Alex Yst <mailto:copyright@y.st>

	This program is free software: you can redistribute it and/or modify
	it under the terms of the GNU General Public License as published by
	the Free Software Foundation, either version 3 of the License, or
	(at your option) any later version.

	This program is distributed in the hope that it will be useful,
	but WITHOUT ANY WARRANTY; without even the implied warranty of
	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
	GNU General Public License for more details.

	You should have received a copy of the GNU General Public License
	along with this program. If not, see <https://www.gnu.org./licenses/>.
-->
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<base href="https://y.st./en/weblog/2017/06-June/14.xhtml" />
		<title>Gotta&apos; go into work tomorrow &lt;https://y.st./en/weblog/2017/06-June/14.xhtml&gt;</title>
		<link rel="icon" type="image/png" href="/link/CC_BY-SA_4.0/y.st./icon.png" />
		<link rel="stylesheet" type="text/css" href="/link/basic.css" />
		<link rel="stylesheet" type="text/css" href="/link/site-specific.css" />
		<script type="text/javascript" src="/script/javascript.js" />
		<meta name="viewport" content="width=device-width" />
	</head>
	<body>
		<nav>
			<p>
				<a href="/en/">Home</a> |
				<a href="/en/a/about.xhtml">About</a> |
				<a href="/en/a/contact.xhtml">Contact</a> |
				<a href="/a/canary.txt">Canary</a> |
				<a href="/en/URI_research/"><abbr title="Uniform Resource Identifier">URI</abbr> research</a> |
				<a href="/en/opinion/">Opinions</a> |
				<a href="/en/coursework/">Coursework</a> |
				<a href="/en/law/">Law</a> |
				<a href="/en/a/links.xhtml">Links</a> |
				<a href="/en/weblog/2017/06-June/14.xhtml.asc">{this page}.asc</a>
			</p>
			<hr/>
			<p>
				Weblog index:
				<a href="/en/weblog/"><abbr title="American Standard Code for Information Interchange">ASCII</abbr> calendars</a> |
				<a href="/en/weblog/index_ol_ascending.xhtml">Ascending list</a> |
				<a href="/en/weblog/index_ol_descending.xhtml">Descending list</a>
			</p>
			<hr/>
			<p>
				Jump to entry:
				<a href="/en/weblog/2015/03-March/07.xhtml">&lt;&lt;First</a>
				<a rel="prev" href="/en/weblog/2017/06-June/13.xhtml">&lt;Previous</a>
				<a rel="next" href="/en/weblog/2017/06-June/15.xhtml">Next&gt;</a>
				<a href="/en/weblog/latest.xhtml">Latest&gt;&gt;</a>
			</p>
			<hr/>
		</nav>
		<header>
			<h1>Gotta&apos; go into work tomorrow</h1>
			<p>Day 00830: Wednesday, 2017 June 14</p>
		</header>
<section id="general">
	<h2>General news</h2>
	<p>
		I spent the morning and into the afternoon walking and biking.
		While I was out, I thought about the barter system I&apos;d like to get set up on my Minetest server.
		It&apos;d be nice to have some sort of cash system, but how would that even work?
		I&apos;ve come up with various options in the past, but I never like how they work.
		One option is to have players start out with a set amount of money when they join the server for the first time.
		More money can be acquired by selling goods to other players.
		However, this encourages users to create several accounts and pipe the money all into their main account&apos;s wallet.
		Another option is to give players a set amount of money every so often.
		However, this encourages players to create several accounts, logging into them every once in a while to transfer cash to the main account.
		Again, artificially encouraging the creation of multiple accounts is something I&apos;d like to avoid.
		With this second plan comes another problem though: inflation.
		The longer you&apos;ve played, the more money you&apos;ll have, even if you don&apos;t work for it.
		The longer the world&apos;s been in use, the less the economy is even good for anything.
		For this reason, the only feasible way I&apos;ve been able to figure out how to get an economy running is through barter.
		However, while I was out, I came up with another plan.
		When mining certain nodes, they can have a one in one hundred (or some other probability) chance of dropping some sort of currency instead of themself.
		To give the currency value, it&apos;d actually be backed; any amount of money placed in the crafting grid in any formation will result in some otherwise-finite resource being crafted.
		This&apos;d fix the problem of lack of renewability in Minetest!
		I think many players will still use barter instead, as the cash will be better used for generating materials from.
		Some players are ... strange, though.
		For example, I knew a player that thought mese shards were great currency.
		They didn&apos;t like that I removed them from my world.
		The problem?
		Mese shards in Minetest at the time were completely worthless.
		You could break a mese crystal into nine shards, but once you did, the shards could never be crafted back into a crystal.
		(This problem has since been fixed, thankfully.)
		Furthermore, there was nothing you could craft out of mese crystal fragments; unless you had a full crystal, all you had was trash.
	</p>
	<p>
		I&apos;m putting <code>minequest</code> away for now to work on this new idea.
		<del>I may or may not pick <code>minequest</code> back up in the future.
		It&apos;s a nice concept, but I think it fills a need I no longer have.
		My goal in the past when modding Minetest has been to use a subtle touch, affecting the state of the game world as little as possible.
		I no longer feel boxed in like that though.
		Minequest is a lot of code that boils down to just being able to customise a character, changing game play without touching the actual world much.
		Honestly, I think I&apos;d like to come back to it at some point, but if and when I do, coming up with all the bonuses is going to take a while.
		It might never be finished.</del>
		<ins>Never mind.
		I just realised that this mod <strong>*has to*</strong> be completed.
		Its completion proves the <code>minestats</code> <abbr title="application programming interface">API</abbr> is complete enough to build off of, and in building <code>minequest</code>, I&apos;ll come across the holes in the <abbr title="application programming interface">API</abbr> that need to be patched.</ins>
	</p>
	<p>
		I wrote up some code to have Minetest tally up the number of possible recipes involving only my new currency.
		There are four hundred!
		There are only three hundred seventy-eight items in Minetest Game, and that doesn&apos;t even remove the items I don&apos;t want to provide recipes for, such as undug minerals, still in their node form.
		Clearly, the initial idea needed refinement.
		I decided to randomise the recipes and support as many items as possible.
		In an otherwise-vanilla copy of Minetest Game, that&apos;d be all of them, but if mods were added, there could be more items than available recipes.
		Next, I needed a way to rule out items that should never be crafted.
		After thinking a while, I decided against the randomisation plan, and instead make two hundred items craftable, each via one of two recipes.
		I&apos;d have some fallbacks for in case some Minetest Game mods weren&apos;t installed, and if too few of the mods were installed, I&apos;d drop the item count to one hundred and provide four recipes each.
		<code>default</code> alone has over one hundred items I&apos;d feel fine making recipes for, and I have to depend on that mod anyway to turn some of the nodes into ores to sometimes dig strange coins from.
	</p>
	<p>
		I came up with an even better idea later though.
		<code>strangecoins</code>, my new money mod, can depend on <code>minestats</code>!
		The dependency will more than likely be soft, but if both are installed, which items you can purchase from the server will depend on your mining/farming stats.
		Nine strange coins can be crafted into a shop node.
		Each purchasable item will have a price, a mineral, and a stat requirement.
		Depending on which stats you increase, you&apos;ll have access to different items to buy.
		Unless you get <strong>*all*</strong> your default stats and all the stats added by <code>strangecoins</code> up to a certain level, there will be some things you just can&apos;t buy.
		I&apos;ll also add an <abbr title="application programming interface">API</abbr> to allow the adding of more stats and more items for purchase to the shop node.
		While sorting purchasable items into what mineral/crop they&apos;d belong to, I found that coal cannot be, even in minute traces, in yellow or white dye.
		Interesting. 
	</p>
	<p>
		I did my laundry early this time, getting it done when I only had one load to do instead of two.
		Strangely, the dryer I used gave me twelve minutes per quarter I fed it, as opposed to the usual ten.
		I wonder if the other dryers are doing this now too.
	</p>
	<p>
		I was planning to stay up and start my coursework tonight; the term begins at 22:00.
		However, I received an email from a coworker.
		They need me to cover a morning shift, which means I need sleep.
		I&apos;ll take a look at the first week&apos;s work before I head out tomorrow so I can think about what I need to submit when I get back.
	</p>
	<p>
		My <a href="/a/canary.txt">canary</a> still sings the tune of freedom and transparency.
	</p>
</section>
<section id="dreams">
	<h2>Dream journal</h2>
	<p>
		I dreamed my mother had encountered a &quot;rock fish&quot;.
		No explanation was given as to what a rock fish actually was, but my mother was confused to have encountered it in the house.
		Apparently, they live inside crumbly rocks.
		I was a bit confused.
		They couldn&apos;t actually be a type of fish that lives on land inside these crumbly rocks, could they?
		Alyssa admitted they&apos;d been crumbling a crumbly rock onto the floor for the past while, so the rock fish had probably come out of that.
		Our mother was annoyed by this, and told Alyssa to clean up the mess.
		I actually encountered the thing later.
		I turns out these rock fish were a type of persistent, flying, biting insect.
		I found it when it bit my shin, and I knocked it off.
		It kept flying at me, and I kept batting it away with whatever I was holding at the time; I forget what that was.
		The insect was mildly annoying at worst though.
	</p>
	<p>
		It&apos;s worth noting that real <a href="https://en.wikipedia.org./wiki/Rockfish">rockfish</a> live in water, <strong>*amongst*</strong> rocks, not in them.
	</p>
</section>
		<hr/>
		<p>
			Copyright © 2017 Alex Yst;
			You may modify and/or redistribute this document under the terms of the <a rel="license" href="/license/gpl-3.0-standalone.xhtml"><abbr title="GNU&apos;s Not Unix">GNU</abbr> <abbr title="General Public License version Three or later">GPLv3+</abbr></a>.
			If for some reason you would prefer to modify and/or distribute this document under other free copyleft terms, please ask me via email.
			My address is in the source comments near the top of this document.
			This license also applies to embedded content such as images.
			For more information on that, see <a href="/en/a/licensing.xhtml">licensing</a>.
		</p>
		<p>
			<abbr title="World Wide Web Consortium">W3C</abbr> standards are important.
			This document conforms to the <a href="https://validator.w3.org./nu/?doc=https%3A%2F%2Fy.st.%2Fen%2Fweblog%2F2017%2F06-June%2F14.xhtml"><abbr title="Extensible Hypertext Markup Language">XHTML</abbr> 5.1</a> specification and uses style sheets that conform to the <a href="http://jigsaw.w3.org./css-validator/validator?uri=https%3A%2F%2Fy.st.%2Fen%2Fweblog%2F2017%2F06-June%2F14.xhtml"><abbr title="Cascading Style Sheets">CSS</abbr>3</a> specification.
		</p>
	</body>
</html>

